import React, { useState, useEffect } from 'react'
import { View, Image, Swiper, SwiperItem } from '@tarojs/components'
import { AtList, AtListItem, AtButton, AtToast } from "taro-ui"

import './index.less'
import "taro-ui/dist/style/components/list.scss";
import Taro from '@tarojs/taro'

export default (props: any) => {
  const { businessTime, tel, address } = props.data
  const telCall = () => {
    Taro.makePhoneCall({
      phoneNumber: tel //仅为示例，并非真实的电话号码
    })
  }
  return (
    <View className='concat'>
      <View className='time'>营业时间：{businessTime}</View>
      <View className='tel'>
        <View>商家电话：{tel}</View>
        <Image onClick={() => { telCall() }} className='telIco' src={IMGSRC + 'tel.png'}></Image>
      </View>
      <View className='tel'>商家地址：{address}</View>
    </View>
  )
}
